package com.haiwen.boot.utils;



public class UserContext {
    public static final String USER_IN_SESSION = "USER_IN_SESSION";
    public static  final String VERIFICATION_CODE="VERIFICATION_CODE";
    public static final String REQUEST_LIMIT = "requestLimit";

    private static   final ThreadLocal local = new ThreadLocal<>();

    public static <T> void set(T parameter) {
        local.set(parameter);
    }

    public static <T> T get() {
        return (T) local.get();
    }
}
